SMAHA05020_청구관리[일반건진].xrw 53 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
  3. <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
  4. <xhtml:head>
  5. <xhtml:title>청구관리</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <reqtrgtlst>
  11. <item>
  12. <sel/>
  13. <hngnm/>
  14. <pid/>
  15. <orddd/>
  16. <dgflag/>
  17. <rrgstno/>
  18. <pkgcd/>
  19. <pkgnm/>
  20. <payinsubamt/>
  21. <payhealcntramt/>
  22. <healexamflag/>
  23. <healexamdetlflag/>
  24. <rsrvdd/>
  25. <rsrvno/>
  26. <healexamgubun/>
  27. <plceflag/>
  28. </item>
  29. </reqtrgtlst>
  30. <reqlst>
  31. <item>
  32. <sel/>
  33. <clamseqno/>
  34. <clamdd/>
  35. <clamamt/>
  36. <payinsubamt/>
  37. <insuadjustamt/>
  38. <incminsuamt/>
  39. <insureduamt/>
  40. <insuaddamt/>
  41. <payhealcntramt/>
  42. <healcntradjustamt/>
  43. <incmhealcntramt/>
  44. <healcntrreduamt/>
  45. <healcntraddamt/>
  46. <clamstat/>
  47. <clamtrgtcd/>
  48. <rtnchkyn/>
  49. <remfact/>
  50. <healexamgubun/>
  51. </item>
  52. </reqlst>
  53. <reqdetllst>
  54. <item>
  55. <sel/>
  56. <clamseqno/>
  57. <clamdd/>
  58. <hngnm/>
  59. <rrgstno/>
  60. <pid/>
  61. <clamamt/>
  62. <payinsubamt/>
  63. <payhealcntramt/>
  64. <insuadjustamt/>
  65. <healcntradjustamt/>
  66. <insureduamt/>
  67. <healcntrreduamt/>
  68. <insuaddamt/>
  69. <healcntraddamt/>
  70. <clamstat/>
  71. <testcd/>
  72. <healexamflag/>
  73. <rsrvdd/>
  74. <rsrvno/>
  75. <healexamgubun/>
  76. </item>
  77. <incm>
  78. <incomedd/>
  79. <incomeflag/>
  80. <chngamt/>
  81. <incomeamt/>
  82. <discamt/>
  83. <remfact/>
  84. <userid/>
  85. <clamseqno/>
  86. <incomeseqno/>
  87. <cashcardflag/>
  88. <clamtrgtcd/>
  89. <incomestat/>
  90. <healexamgubun/>
  91. </incm>
  92. </reqdetllst>
  93. </main>
  94. <send>
  95. <srchhealexamflag/>
  96. <srchhealexamgubun/>
  97. <srchhealexamgubun2/>
  98. <srchfromdd/>
  99. <srchtodd/>
  100. <srchhealexamdetlflag/>
  101. <srchplceflag/>
  102. <srchplceflag2/>
  103. <srchreqtype/>
  104. <srchcmpycd/>
  105. <srchcmpynm/>
  106. <srchclamfromdd/>
  107. <srchclamtodd/>
  108. <srchclamstat>N</srchclamstat>
  109. <srchclamcretflag/>
  110. <srchclamsisfilename/>
  111. <srchclamseqno/>
  112. <cretsave>
  113. <reqcret/>
  114. <sisfilename/>
  115. </cretsave>
  116. <reqsave>
  117. <reqdata/>
  118. <reqdetldata/>
  119. </reqsave>
  120. <detl/>
  121. </send>
  122. <init>
  123. <baseinfo>
  124. <chedetlflaglst/>
  125. <ghedetlflaglst/>
  126. <asktype/>
  127. <hedetlflaglst>
  128. <item/>
  129. </hedetlflaglst>
  130. <incomeflaglst/>
  131. <healexamgubun/>
  132. <plceflag/>
  133. </baseinfo>
  134. </init>
  135. <hidden>
  136. <exeinfo>
  137. <exe/>
  138. </exeinfo>
  139. </hidden>
  140. <temp>
  141. <count>0</count>
  142. <payinsubamt>0</payinsubamt>
  143. <payhealcntramt>0</payhealcntramt>
  144. </temp>
  145. </root>
  146. </instance>
  147. <submission id="TRZBC00101"/>
  148. <submission id="TRAHA05021" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/reqtrgtlst"/>
  149. <submission id="TRAHA05022" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/reqlst"/>
  150. <submission id="TRAHA05023" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/detl" resultref="/root/main/reqdetllst"/>
  151. <submission id="TXAHA05021" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/cretsave" resultref="/root/hidden/exeinfo"/>
  152. <submission id="TXAHA05022" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/reqsave" resultref="/root/hidden/exeinfo"/>
  153. <submission id="TXAHA05023" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/reqsave" resultref="/root/hidden/exeinfo"/>
  154. <submission id="TXAHA05027" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/cretsave" resultref="/root/hidden/exeinfo"/>
  155. <submission id="TRPAO00005" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/magm/magminfo" resultref="/root/magm/aprvinfo"/>
  156. <submission id="TRPAO00006" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/rcptuser/rcptuserinfosend" resultref="/root/rcptuser/rcptuserinfo"/>
  157. </model>
  158. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  159. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  160. <script type="javascript" src="../../../com/commonweb/js/utilHelper.js"/>
  161. <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
  162. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  163. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  164. <script type="javascript" src="../../../com/zipcodeweb/js/ZBP001.js"/>
  165. <script type="javascript" src="../../../pam/pamcomnweb/js/PAM.js"/>
  166. <script type="javascript" src="../../../ast/healexamweb/js/AHA001.js"/>
  167. <script type="javascript" src="../../../ast/healexamweb/js/AHA010.js"/>
  168. <script type="javascript" src="../../../ast/commonweb/js/AST.js"/>
  169. <script type="javascript" ev:event="xforms-ready">
  170. <![CDATA[
  171. var sFlag = getScreenMenuParameter();
  172. if(sFlag == ""){
  173. sFlag = "G01";
  174. }
  175. m_vHealexamflag = sFlag.substr(0, 1);
  176. m_vHealexamdetlflag = sFlag;
  177. fGetBaseInfo();
  178. fInitCtrl(true);
  179. // var curDt = "20120911";
  180. // model.setValue(ipt_rsvfrdd.attribute("ref") , curDt);
  181. // model.setValue(ipt_rsvtodd.attribute("ref") , curDt);
  182. // model.setValue(ipt_clamfromdd.attribute("ref") , curDt);
  183. // model.setValue(ipt_clamtodd.attribute("ref") , curDt);
  184. // btn_reqcret.selected = true;
  185. // model.toggle("case_cret");
  186. // btn_reqmngt.selected = true;
  187. // model.toggle("case_mngt");
  188. model.refresh();
  189. ]]>
  190. </script>
  191. <script type="javascript">
  192. <![CDATA[
  193. m_vHealexamflag = "";
  194. m_vHealexamdetlflag = "";
  195. function fGetBaseInfo(){
  196. zbcfGetCodeList(new Array("A0069", "A0070", "A0108", "A0458", "A0088", "A0110"),
  197. new Array("/root/init/baseinfo/chedetlflaglst"
  198. ,"/root/init/baseinfo/ghedetlflaglst"
  199. ,"/root/init/baseinfo/asktype"
  200. ,"/root/init/baseinfo/incomeflaglst"
  201. ,"/root/init/baseinfo/healexamgubun"
  202. ,"/root/init/baseinfo/plceflag"
  203. ));
  204. copyNodesetType("/root/init/baseinfo/hedetlflaglst/item" , "/root/init/baseinfo/chedetlflaglst/A0069", "replace");
  205. copyNodesetType("/root/init/baseinfo/hedetlflaglst/item" , "/root/init/baseinfo/ghedetlflaglst/A0070", "after");
  206. astfAddCombo("/root/init/baseinfo/healexamgubun", "A0088", "cdid,cdnm", ",전체");
  207. astfAddCombo("/root/init/baseinfo/plceflag", "A0110", "cdid,cdnm", ",전체");
  208. cmb_srchplceflag.select(2);
  209. model.setValue("/root/send/srchhealexamflag" , m_vHealexamflag);
  210. model.setValue("/root/send/srchhealexamdetlflag" , m_vHealexamdetlflag);
  211. }
  212. function fInitCtrl(bAll){
  213. if(bAll == true){
  214. var curDt = getCurrentDate();
  215. model.setValue(ipt_rsvfrdd.attribute("ref") , curDt);
  216. model.setValue(ipt_rsvtodd.attribute("ref") , curDt);
  217. model.setValue(ipt_clamfromdd.attribute("ref") , curDt);
  218. model.setValue(ipt_clamtodd.attribute("ref") , curDt);
  219. cmb_reqtype.select(0);
  220. grd_reqcretlst.fixedcellcheckbox(0 , grd_reqcretlst.colRef("sel")) = true;
  221. grd_reqdetllst.fixedcellcheckbox(0 , grd_reqdetllst.colRef("sel")) = true;
  222. btn_reqcret.selected = true;
  223. model.toggle("case_cret");
  224. }
  225. }
  226. /********************************************************************************************************************************
  227. * 청구생성 할 대상을 조회
  228. *********************************************************************************************************************************/
  229. function fGetReqCretList() {
  230. submit("TRAHA05021");
  231. }
  232. /********************************************************************************************************************************
  233. * 선택된 청구대상자 금액 합계 출력
  234. *********************************************************************************************************************************/
  235. function fGetReqCretSum(){
  236. var count = 0;
  237. var payinsubamt = 0;
  238. var payhealcntramt = 0;
  239. /*
  240. for(var i=1; i<grd_reqcretlst.rows; i++){
  241. if(grd_reqcretlst.valueMatrix(i, grd_reqcretlst.colRef("sel")) == "Y"){
  242. count += 1;
  243. payinsubamt += parseInt(grd_reqcretlst.valueMatrix(i, grd_reqcretlst.colRef("payinsubamt")));
  244. payhealcntramt += parseInt(grd_reqcretlst.valueMatrix(i, grd_reqcretlst.colRef("payhealcntramt")));
  245. }
  246. }
  247. */
  248. for(var i=0 ; i<grd_reqcretlst.selectedRows; i++){
  249. count += 1;
  250. payinsubamt += parseInt(grd_reqcretlst.valueMatrix(grd_reqcretlst.selectedRow(i), grd_reqcretlst.colRef("payinsubamt")));
  251. payhealcntramt += parseInt(grd_reqcretlst.valueMatrix(grd_reqcretlst.selectedRow(i), grd_reqcretlst.colRef("payhealcntramt")));
  252. }
  253. model.setValue("/root/temp/count" , count);
  254. model.setValue("/root/temp/payinsubamt" , payinsubamt);
  255. model.setValue("/root/temp/payhealcntramt" , payhealcntramt);
  256. model.refresh();
  257. }
  258. /********************************************************************************************************************************
  259. * 청구생성
  260. *********************************************************************************************************************************/
  261. function fSetReqCret(){
  262. if(model.getValue("/root/send/srchhealexamgubun") == ""){
  263. messageBox("건진구분 ", "E014");
  264. return;
  265. }
  266. if(model.getValue("/root/send/srchplceflag") == ""){
  267. messageBox("건진장소 ", "E014");
  268. return;
  269. }
  270. if(model.getValue("/root/send/cretsave/sisfilename") == ""){
  271. messageBox("파일명 ", "E014");
  272. return;
  273. }
  274. grd_reqcretlst.clearStatus();
  275. model.resetInstanceNode("/root/send/cretsave/reqcret");
  276. for(var i=1; i < grd_reqcretlst.rows; i++){
  277. var chk = grd_reqcretlst.valueMatrix( i, grd_reqcretlst.colRef("sel"));
  278. if(chk == "Y"){
  279. model.setValue("/root/main/reqtrgtlst/item["+ i +"]/cretflag" , model.getValue("/root/send/srchreqtype"));
  280. model.setValue("/root/main/reqtrgtlst/item["+ i +"]/plceflag" , model.getValue("/root/send/srchplceflag"));
  281. model.setValue("/root/main/reqtrgtlst/item["+ i +"]/sisfilename" , model.getValue("/root/send/cretsave/sisfilename"));
  282. grd_reqcretlst.addStatus(i, "insert");
  283. }
  284. }
  285. var cretData = getGridUpdateData(grd_reqcretlst);
  286. if(cretData != ""){
  287. model.makeValue("/root/send/cretsave/reqcret", cretData);
  288. if(submit("TXAHA05021")){
  289. fGetReqCretList(); //청구생성 할 대상을 조회
  290. fGetClamList(); //청구내역 조회
  291. model.setValue("/root/send/cretsave/sisfilename", "");
  292. }
  293. }else {
  294. messageBox("생성할 내역이 ", "E014");
  295. return;
  296. }
  297. model.refresh();
  298. }
  299. /********************************************************************************************************************************
  300. * 청구내역 조회
  301. *********************************************************************************************************************************/
  302. function fGetClamList(){
  303. if(submit("TRAHA05022")){
  304. model.resetInstanceNode(grd_reqdetllst.nodeset);
  305. model.resetInstanceNode(grd_incmlst.nodeset);
  306. grd_reqdetllst.rebuild();
  307. grd_incmlst.rebuild();
  308. for(var i=1; i<grd_reqlst.rows; i++){
  309. var clamStat = grd_reqlst.valueMatrix(i,grd_reqlst.colRef("clamstat"));
  310. if(clamStat == "Y"){
  311. grd_reqlst.isReadOnly(i , grd_reqlst.colRef("adjustamt")) = true;
  312. grd_reqlst.isReadOnly(i , grd_reqlst.colRef("reduamt")) = true;
  313. grd_reqlst.isReadOnly(i , grd_reqlst.colRef("payinsuaddamt")) = true;
  314. }
  315. }
  316. fSetAmtSum();
  317. }
  318. }
  319. /********************************************************************************************************************************
  320. * 청구상세내역 조회
  321. *********************************************************************************************************************************/
  322. function fGetClamDetlList(){
  323. model.resetInstanceNode(grd_reqdetllst.nodeset);
  324. model.resetInstanceNode("/root/send/detl");
  325. var idx = grd_reqlst.row;
  326. for(var i=1; i < grd_reqlst.rows; i++){
  327. if(i == idx){
  328. if(grd_reqlst.valueMatrix( i , grd_reqlst.colRef("sel")) == "Y"){
  329. copyNodesetType("/root/send/detl", grd_reqlst.nodeset + "[" + idx + "]", "replace");
  330. }
  331. }else{
  332. grd_reqlst.valueMatrix(i, grd_reqlst.colRef("sel")) = "N";
  333. }
  334. }
  335. if(submit("TRAHA05023")){
  336. fSetDetAmtSum();
  337. }
  338. }
  339. /********************************************************************************************************************************
  340. * 청구취소
  341. *********************************************************************************************************************************/
  342. function fExeClamCncl(vClamFlag) {
  343. if(vClamFlag == null || vClamFlag == "") return;
  344. model.resetInstanceNode("/root/send/reqsave/execlamflag");
  345. model.resetInstanceNode("/root/send/reqsave/reqdata");
  346. model.resetInstanceNode("/root/send/reqsave/reqdetldata");
  347. grd_reqlst.clearStatus();
  348. var cnclCnt = 0;
  349. for(var i=1; i<grd_reqlst.rows; i++){
  350. var srcClamStat = grd_reqlst.valueMatrix( i , grd_reqlst.colRef("clamstat"));
  351. if(grd_reqlst.valueMatrix( i , grd_reqlst.colRef("sel")) == "Y"){
  352. if(grd_reqlst.valueMatrix(i , grd_reqlst.colRef("clamstat")) == "C"){
  353. cnclCnt++;
  354. }
  355. grd_reqlst.addStatus( i , "insert");
  356. }
  357. }
  358. if(cnclCnt > 0) {
  359. messageBox("이미 청구취소 된 내역" ,"E008");
  360. return;
  361. }
  362. var reqData = getGridUpdateData(grd_reqlst);
  363. if(reqData != ""){
  364. if(grd_incmlst.rows > 1){
  365. messageBox("입금내역이 존재하는 청구내역은 청구취소", "E001");
  366. return;
  367. }
  368. model.makeValue("/root/send/reqsave/reqdata" , reqData);
  369. model.makeValue("/root/send/reqsave/execlamflag" , vClamFlag)
  370. if(submit("TXAHA05022")) {
  371. grd_reqlst.clearStatus();
  372. grd_reqdetllst.clearStatus();
  373. fGetClamList(); //청구내역 조회
  374. for(var i=1; i<grd_reqlst.rows; i++){
  375. if(grd_reqlst.valueMatrix( i , grd_reqlst.colRef("clamseqno")) == model.getValue("/root/send/detl/clamseqno")) {
  376. grd_reqlst.valueMatrix( i , grd_reqlst.colRef("sel")) = "Y";
  377. if(submit("TRAHA05023")) {
  378. fSetDetAmtSum();
  379. }
  380. }
  381. }
  382. }
  383. }else {
  384. messageBox("청구 내역이 " , "E014");
  385. return;
  386. }
  387. }
  388. /********************************************************************************************************************************
  389. * 청구부분 반환
  390. *********************************************************************************************************************************/
  391. function fSetRtnClam() {
  392. grd_reqdetllst.clearStatus();
  393. var endCnt = 0;
  394. var cnclCnt = 0;
  395. var rtnCnt = 0;
  396. for(var i=0; i<grd_reqdetllst.rows; i++){
  397. if(grd_reqdetllst.valueMatrix( i , grd_reqdetllst.colRef("sel")) == "Y"){
  398. var clamstat = grd_reqdetllst.valueMatrix( i , grd_reqdetllst.colRef("clamstat"));
  399. grd_reqdetllst.addStatus(i, "insert");
  400. if(clamstat == "Y") endCnt++;
  401. if(clamstat == "C") cnclCnt++;
  402. if(clamstat == "R") rtnCnt++;
  403. }
  404. }
  405. if(endCnt > 0){
  406. messageBox("청구완료 내역을 반환 할수","I004");
  407. return;
  408. }
  409. if(cnclCnt > 0){
  410. messageBox("청구취소 내역을 반환 할수","I004");
  411. return;
  412. }
  413. if(rtnCnt > 0){
  414. messageBox("청구반환 내역을 반환 할수","I004");
  415. return;
  416. }
  417. var rtnData = getGridUpdateData(grd_reqdetllst);
  418. if(rtnData != ""){
  419. model.makeValue("/root/send/reqsave/rtndata", rtnData);
  420. if(submit("TXAHA05023")){
  421. fGetClamList(); //청구내역 조회
  422. for(var i = 1; i < grd_reqlst.rows; i++){
  423. if(grd_reqlst.valueMatrix( i , grd_reqlst.colRef("clamseqno")) == model.getValue("/root/send/detl/clamseqno")){
  424. grd_reqlst.valueMatrix( i , grd_reqlst.colRef("sel")) = "Y";
  425. if(submit("TRAHA05023")){
  426. fSetDetAmtSum();
  427. }
  428. }
  429. }
  430. }
  431. }else{
  432. messageBox("반환 내역이 " , "E014");
  433. return;
  434. }
  435. }
  436. /********************************************************************************************************************************
  437. * 입금저장
  438. *********************************************************************************************************************************/
  439. function fSetClamIncm(vClamFlag) {
  440. if(vClamFlag == "" || vClamFlag == null) return;
  441. model.resetInstanceNode("/root/send/reqsave/execlamflag");
  442. model.resetInstanceNode("/root/send/reqsave/reqdata");
  443. model.resetInstanceNode("/root/send/reqsave/reqdetldata");
  444. var reqData = "";
  445. var reqDetlData = "";
  446. var cnclCnt = 0;
  447. grd_reqlst.clearStatus();
  448. grd_reqdetllst.clearStatus();
  449. //청구내역
  450. for( var i=1; i < grd_reqlst.rows; i++){
  451. if(grd_reqlst.valueMatrix( i , grd_reqlst.colRef("sel")) == "Y"){
  452. if(grd_reqlst.valueMatrix(i, grd_reqlst.colRef("clamstat")) == "C"){
  453. cnclCnt++;
  454. }
  455. grd_reqlst.addStatus(i, "insert");
  456. }
  457. }
  458. //청구상세내역
  459. for(var j=1; j < grd_reqdetllst.rows-1; j++){
  460. if(grd_reqdetllst.valueMatrix(j ,grd_reqdetllst.colRef("clamstat")) != ""){
  461. grd_reqdetllst.addStatus(j , "insert");
  462. }
  463. }
  464. var reqData = getGridUpdateData(grd_reqlst);
  465. var reqDetlData = getGridUpdateData(grd_reqdetllst);
  466. if(cnclCnt > 0){
  467. messageBox("청구취소 내역은 입금저장" , "E001");
  468. return;
  469. }
  470. if(reqData == ""){
  471. messageBox("선택된 내역이" , "I004");
  472. return;
  473. }
  474. model.makeValue("/root/send/reqsave/reqdata" , reqData);
  475. model.makeValue("/root/send/reqsave/reqdetldata" , reqDetlData);
  476. model.makeValue("/root/send/reqsave/execlamflag" , vClamFlag);
  477. if(submit("TXAHA05022")){
  478. grd_reqlst.clearStatus();
  479. grd_reqdetllst.clearStatus();
  480. fGetClamList(); //청구내역 조회
  481. for(var i = 1; i < grd_reqlst.rows; i++) {
  482. if(grd_reqlst.valueMatrix( i , grd_reqlst.colRef("clamseqno")) == model.getValue("/root/send/detl/clamseqno")){
  483. grd_reqlst.valueMatrix( i , grd_reqlst.colRef("sel")) = "Y";
  484. if(submit("TRAHA05023")){
  485. fSetDetAmtSum();
  486. }
  487. }
  488. }
  489. }
  490. }
  491. /********************************************************************************************************************************
  492. * 청구내역을 수정한다. (청구구분, 파일명, 비고사항)
  493. *********************************************************************************************************************************/
  494. function fSetCret(){
  495. grd_reqlst.clearStatus();
  496. model.resetInstanceNode("/root/send/cretsave/reqcret");
  497. for(var i=1; i < grd_reqlst.rows; i++){
  498. var chk = grd_reqlst.valueMatrix( i, grd_reqlst.colRef("sel"));
  499. if(chk == "Y"){
  500. grd_reqlst.addStatus(i, "insert");
  501. }
  502. }
  503. var cretData = getGridUpdateData(grd_reqlst);
  504. if(cretData != "") {
  505. model.makeValue("/root/send/cretsave/reqcret", cretData);
  506. if(submit("TXAHA05027")){
  507. fGetReqCretList(); //청구생성 할 대상을 조회
  508. fGetClamList(); //청구내역 조회
  509. }
  510. }else {
  511. messageBox("저장 내역이 ", "E014");
  512. return;
  513. }
  514. }
  515. /********************************************************************************************************************************
  516. * 청구내역 총계를 생성한다.
  517. *********************************************************************************************************************************/
  518. function fSetAmtSum(){
  519. grd_reqlst.subtotalPosition = "below";
  520. //grd_reqlst.multiTotals = true;
  521. grd_reqlst.subtotal("clear", -1, i, "format:(-,+)#,###; roundmode:round; roundpostion:2", "background-color:#99ff99; font-weight:bold", 2, "총계" );
  522. for(var i=0; i < grd_reqlst.cols; i++){
  523. if(i>= grd_reqlst.colRef("clamamt") && i<grd_reqlst.colRef("clamstat")){
  524. grd_reqlst.subtotal("sum", -1, i, "format:(-,+)#,###; roundmode:round; roundpostion:2", "background-color:#99ff99; font-weight:bold", 2, "총계" );
  525. }
  526. }
  527. }
  528. /********************************************************************************************************************************
  529. * 청구상세내역 총계를 생성한다.
  530. *********************************************************************************************************************************/
  531. function fSetDetAmtSum() {
  532. grd_reqdetllst.subtotalPosition = "below";
  533. //grd_reqdetllst.multiTotals = true;
  534. grd_reqdetllst.subtotal("clear", -1, i, "format:(-,+)#,###; roundmode:round; roundpostion:2", "background-color:#99ff99; font-weight:bold", 2, "총계" );
  535. for(var i=0; i < grd_reqdetllst.cols-5; i++){
  536. if(i >= grd_reqdetllst.colRef("clamamt") && i<grd_reqlst.colRef("clamstat")){
  537. grd_reqdetllst.subtotal("sum", -1, i, "format:(-,+)#,###; roundmode:round; roundpostion:2", "background-color:#99ff99; font-weight:bold", 2, "총계" );
  538. }
  539. }
  540. }
  541. /********************************************************************************************************************************
  542. * 청구내역
  543. * 공단금액, 보건소금액 > 공단입금액 보건입금액 복사
  544. *********************************************************************************************************************************/
  545. function fSetAmtCopy(){
  546. var chkYn = "N";
  547. for(var i=1; i < grd_reqlst.rows-1; i++){
  548. var chk = grd_reqlst.valueMatrix(i, grd_reqlst.colRef("sel"));
  549. if(chk == "Y"){
  550. model.setValue("/root/main/reqlst/item["+ i +"]/incminsuamt" , model.getValue("/root/main/reqlst/item["+ i +"]/insuadjustamt"));
  551. model.setValue("/root/main/reqlst/item["+ i +"]/incmhealcntramt" , model.getValue("/root/main/reqlst/item["+ i +"]/healcntradjustamt"));
  552. chkYn = "Y";
  553. }
  554. }
  555. if(chkYn == "N"){
  556. messageBox("선택된 내역이 ", "E014");
  557. return;
  558. }
  559. fSetAmtSum();
  560. model.refresh();
  561. }
  562. /********************************************************************************************************************************
  563. * 청구상세내역
  564. * 공단금액, 보건소금액 > 공단조정액, 보건조정액 복사
  565. *********************************************************************************************************************************/
  566. function fSetDetAmtCopy(){
  567. for(var i=1; i < grd_reqdetllst.rows-1; i++){
  568. model.setValue("/root/main/reqdetllst/item["+ i +"]/insuadjustamt" , model.getValue("/root/main/reqdetllst/item["+ i +"]/payinsubamt"));
  569. model.setValue("/root/main/reqdetllst/item["+ i +"]/healcntradjustamt" , model.getValue("/root/main/reqdetllst/item["+ i +"]/payhealcntramt"));
  570. }
  571. fSetDetAmtSum();
  572. model.refresh();
  573. }
  574. ]]>
  575. </script>
  576. </xhtml:head>
  577. <xhtml:body style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  578. <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
  579. <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">공단청구관리</caption>
  580. </group>
  581. <group id="grp_biz" scroll="auto" style="left:0px; top:13px; width:1195px; height:744px; ">
  582. <button id="btn_reqmngt" class="btn_sw" group="tab" selected="true" style="left:89px; top:5px; width:94px; height:22px; ">
  583. <caption>청구/반송관리</caption>
  584. <toggle case="case_mngt" ev:event="onclick"/>
  585. </button>
  586. <button id="btn_reqcret" class="btn_sw" group="tab" selected="true" style="left:5px; top:5px; width:84px; height:22px; ">
  587. <caption>청구생성</caption>
  588. <toggle case="case_cret" ev:event="onclick"/>
  589. </button>
  590. <switch id="swt_req" style="left:5px; top:27px; width:1185px; height:712px; ">
  591. <case id="case_cret" selected="true">
  592. <shape id="roundrect1" class="roundrect_search" appearance="roundrect" style="left:0px; top:0px; width:1183px; height:70px; "/>
  593. <caption id="caption1" class="search_name" style="left:5px; top:10px; width:98px; height:17px; ">건진구분 :</caption>
  594. <select1 id="combo1" ref="/root/send/srchhealexamdetlflag" disabled="true" appearance="minimal" style="left:95px; top:10px; width:130px; height:19px; ">
  595. <choices>
  596. <itemset nodeset="/root/init/baseinfo/hedetlflaglst/item">
  597. <label ref="cdnm"/>
  598. <value ref="cdid"/>
  599. </itemset>
  600. </choices>
  601. </select1>
  602. <caption id="caption10" class="search_name" style="left:230px; top:10px; width:230px; height:17px; ">건진일자 : ~</caption>
  603. <input id="ipt_rsvfrdd" ref="/root/send/srchfromdd" class="input_s_essential" inputtype="date" style="left:320px; top:10px; width:95px; height:19px; "/>
  604. <input id="ipt_rsvtodd" ref="/root/send/srchtodd" class="input_s_essential" inputtype="date" style="left:435px; top:10px; width:95px; height:19px; "/>
  605. <caption id="caption15" class="search_name" style="left:540px; top:10px; width:94px; height:17px; ">건진구분 :</caption>
  606. <select1 id="cmb_srchhealexamgubun1" ref="/root/send/srchhealexamgubun" class="combo_search" appearance="minimal" style="left:630px; top:10px; width:110px; height:19px; ">
  607. <choices>
  608. <itemset nodeset="/root/init/baseinfo/healexamgubun/A0088">
  609. <label ref="cdnm"/>
  610. <value ref="cdid"/>
  611. </itemset>
  612. </choices>
  613. </select1>
  614. <caption id="caption36" class="search_name" style="left:750px; top:10px; width:89px; height:17px; ">건진장소 :</caption>
  615. <select1 id="cmb_srchplceflag" ref="/root/send/srchplceflag" class="combo_search" appearance="minimal" style="left:840px; top:10px; width:60px; height:19px; ">
  616. <choices>
  617. <itemset nodeset="/root/init/baseinfo/plceflag/A0110">
  618. <label ref="cdnm"/>
  619. <value ref="cdid"/>
  620. </itemset>
  621. </choices>
  622. </select1>
  623. <caption id="caption7" class="search_name" style="left:905px; top:10px; width:94px; height:17px; ">청구구분 :</caption>
  624. <select1 id="cmb_reqtype" ref="/root/send/srchreqtype" class="combo_search" appearance="minimal" style="left:995px; top:10px; width:110px; height:19px; ">
  625. <choices>
  626. <item>
  627. <label>일반건진</label>
  628. <value>1</value>
  629. </item>
  630. <item>
  631. <label>구강건진</label>
  632. <value>2</value>
  633. </item>
  634. <item>
  635. <label>암건진</label>
  636. <value>3</value>
  637. </item>
  638. <item>
  639. <label>영유아검진</label>
  640. <value>4</value>
  641. </item>
  642. </choices>
  643. </select1>
  644. <caption id="caption4" class="search_name" style="left:5px; top:40px; width:86px; height:17px; ">사 업 장 :</caption>
  645. <input id="ipt_srchcmpycd" ref="/root/send/srchcmpycd" class="input_search" style="left:90px; top:40px; width:85px; height:19px; ">
  646. <script type="javascript" ev:event="onkeyup">
  647. <![CDATA[
  648. inputEnterKey("btn_selcmpy", "DOMActivate");
  649. ]]>
  650. </script>
  651. </input>
  652. <button id="btn_selcmpy" class="icon_search" style="left:182px; top:40px; width:16px; height:16px; ">
  653. <caption/>
  654. <script type="javascript" ev:event="DOMActivate">
  655. <![CDATA[
  656. fGetComnCd("SMAHA01500", "09" , "cd", ipt_srchcmpycd.currentText ,ipt_srchcmpycd.attribute("ref"), opt_srchcmpynm.attribute("ref"));
  657. ]]>
  658. </script>
  659. </button>
  660. <output id="opt_srchcmpynm" ref="/root/send/srchcmpynm" class="output_fix" style="left:205px; top:40px; width:185px; height:19px; "/>
  661. <caption id="caption16" class="search_name" style="left:395px; top:40px; width:86px; height:17px; ">파일명 :</caption>
  662. <input id="input1" ref="/root/send/cretsave/sisfilename" class="input_search" style="left:470px; top:40px; width:205px; height:19px; "/>
  663. <button id="btn_srch" class="btn1_letter2" style="left:1119px; top:24px; width:56px; height:22px; ">
  664. <caption>조회</caption>
  665. <script type="javascript" ev:event="DOMActivate">
  666. <![CDATA[
  667. fGetReqCretList(); //청구생성 할 대상을 조회
  668. fGetReqCretSum();
  669. ]]>
  670. </script>
  671. </button>
  672. <caption id="caption3" class="tit_2" style="left:5px; top:75px; width:111px; height:14px; ">청구대상자</caption>
  673. <output id="count" ref="/root/temp/count" format="(-)#,###" style="left:261px; top:75px; width:55px; height:19px; font-weight:bold; color:#ff0000; text-align:right; "/>
  674. <caption id="caption2" style="left:316px; top:78px; width:30px; height:14px; font-weight:bold; color:#ff0000; ">명</caption>
  675. <output id="payinsubamt" ref="/root/temp/payinsubamt" format="(-)#,###" style="left:330px; top:75px; width:105px; height:19px; font-weight:bold; color:#ff0000; text-align:right; "/>
  676. <output id="payhealcntramt" ref="/root/temp/payhealcntramt" format="(-)#,###" style="left:432px; top:75px; width:105px; height:19px; font-weight:bold; color:#ff0000; text-align:right; "/>
  677. <button id="button1" class="btn2_letter4" style="left:1112px; top:73px; width:64px; height:19px; ">
  678. <caption>엑셀저장</caption>
  679. <script type="javascript" ev:event="DOMActivate">
  680. <![CDATA[
  681. var fileName = window.fileDialog("save", ",", false, "excel", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  682. if(fileName != "") grd_reqcretlst.saveExcel(fileName, "SheetName", false, false, "", "", false);
  683. ]]>
  684. </script>
  685. </button>
  686. <line id="line1" class="line_4" style="x1:1113px; y1:8px; x2:1113px; y2:60px; "/>
  687. <line id="line2" class="line_1" style="x1:5px; y1:94px; x2:1177px; y2:94px; "/>
  688. <datagrid id="grd_reqcretlst" nodeset="/root/main/reqtrgtlst/item" caption="^성명^주민번호^공단금액^보건소(국고)금액^건진일자^등록번호^1/2차구분^패키지^패키지명^healexamflag^healexamdetlflag^rsrvdd^rsrvno^cretflag^sisfilename^healexamgubun^plceflag" colsep="^" colwidth="40, 100, 150, 100, 100, 100, 100, 100, 100, 200, 100, 100, 100, 100, 100, 100, 100" explorerbar="sortshow" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:5px; top:99px; width:1172px; height:606px; ">
  689. <col checkvalue="Y,N" ref="sel" type="checkbox"/>
  690. <col ref="hngnm" style="text-align:center; "/>
  691. <col ref="rrgstno" format="999999-9999999" style="text-align:center; "/>
  692. <col ref="payinsubamt" format="(-,+)#,###" style="text-align:right; "/>
  693. <col ref="payhealcntramt" format="(-,+)#,###" style="text-align:right; "/>
  694. <col ref="orddd" format="yyyy-mm-dd" style="text-align:center; "/>
  695. <col ref="pid" style="text-align:center; "/>
  696. <col disabled="true" ref="dgflag" type="combo" style="text-align:center; ">
  697. <choices>
  698. <item>
  699. <label>1차</label>
  700. <value>1</value>
  701. </item>
  702. <item>
  703. <label>2차</label>
  704. <value>2</value>
  705. </item>
  706. </choices>
  707. </col>
  708. <col ref="pkgcd"/>
  709. <col ref="pkgnm" style="text-align:left; "/>
  710. <col ref="healexamflag" visibility="hidden"/>
  711. <col ref="healexamdetlflag" visibility="hidden"/>
  712. <col ref="rsrvdd" visibility="hidden"/>
  713. <col ref="rsrvno" visibility="hidden"/>
  714. <col ref="cretflag" visibility="hidden"/>
  715. <col ref="sisfilename" visibility="hidden"/>
  716. <col ref="healexamgubun" visibility="hidden"/>
  717. <col ref="plceflag" visibility="hidden"/>
  718. <script type="javascript" ev:event="onaftersort">
  719. <![CDATA[
  720. grd_reqcretlst.gridToInstance();
  721. ]]>
  722. </script>
  723. <script type="javascript" ev:event="onmouseup">
  724. <![CDATA[
  725. fGetReqCretSum();
  726. ]]>
  727. </script>
  728. <script type="javascript" ev:event="xforms-value-changed">
  729. <![CDATA[
  730. if(isDataCell()){
  731. if(grd_reqcretlst.isCell(event.target) && grd_reqcretlst.col == "1" && grd_reqcretlst.valueMatrix(grd_reqcretlst.row, grd_reqcretlst.colRef("sel")) == "Y"){
  732. var hngnm = grd_reqcretlst.valueMatrix(grd_reqcretlst.row, grd_reqcretlst.colRef("hngnm"));
  733. var rrgstno = grd_reqcretlst.valueMatrix(grd_reqcretlst.row, grd_reqcretlst.colRef("rrgstno"));
  734. for(var i=1; i<grd_reqcretlst.rows; i++){
  735. if(hngnm == grd_reqcretlst.valueMatrix(i, grd_reqcretlst.colRef("hngnm")) && rrgstno != grd_reqcretlst.valueMatrix(i, grd_reqcretlst.colRef("rrgstno"))){
  736. messageBox("청구대상자 리스트에 동명이인이","I010");
  737. return;
  738. }
  739. }
  740. }
  741. }
  742. ]]>
  743. </script>
  744. </datagrid>
  745. </case>
  746. <case id="case_mngt">
  747. <shape id="roundrect2" class="roundrect_search" appearance="roundrect" style="left:0px; top:0px; width:1183px; height:65px; "/>
  748. <caption id="caption5" class="search_name" style="left:5px; top:10px; width:98px; height:17px; ">청구일자 :</caption>
  749. <input id="ipt_clamfromdd" ref="/root/send/srchclamfromdd" class="input_s_essential" inputtype="date" style="left:95px; top:10px; width:95px; height:19px; "/>
  750. <caption id="caption9" class="search_n_b" style="left:195px; top:10px; width:12px; height:17px; font-weight:bolder; ">~</caption>
  751. <input id="ipt_clamtodd" ref="/root/send/srchclamtodd" class="input_s_essential" inputtype="date" style="left:210px; top:10px; width:95px; height:19px; "/>
  752. <caption id="caption13" class="search_name" style="left:310px; top:10px; width:98px; height:17px; ">청구상태 :</caption>
  753. <select id="checkbox1" ref="/root/send/srchclamstat" overflow="visible" appearance="full" cols="3" sep="▦" style="left:400px; top:13px; width:180px; height:20px; border-style:none; ">
  754. <choices>
  755. <item>
  756. <label>청구</label>
  757. <value>N</value>
  758. </item>
  759. <item>
  760. <label>청구취소</label>
  761. <value>C</value>
  762. </item>
  763. <item>
  764. <label>청구완료</label>
  765. <value>Y</value>
  766. </item>
  767. </choices>
  768. </select>
  769. <caption id="caption8" class="search_name" style="left:590px; top:10px; width:94px; height:17px; ">건진구분 :</caption>
  770. <select1 id="cmb_srchhealexamgubun2" ref="/root/send/srchhealexamgubun2" class="combo_search" appearance="minimal" style="left:680px; top:10px; width:80px; height:19px; ">
  771. <choices>
  772. <itemset nodeset="/root/init/baseinfo/healexamgubun/A0088">
  773. <label ref="cdnm"/>
  774. <value ref="cdid"/>
  775. </itemset>
  776. </choices>
  777. </select1>
  778. <caption id="caption11" class="search_name" style="left:770px; top:10px; width:89px; height:17px; ">건진장소 :</caption>
  779. <select1 id="cmb_srchplceflag2" ref="/root/send/srchplceflag2" class="combo_search" appearance="minimal" style="left:860px; top:10px; width:60px; height:19px; ">
  780. <choices>
  781. <itemset nodeset="/root/init/baseinfo/plceflag/A0110">
  782. <label ref="cdnm"/>
  783. <value ref="cdid"/>
  784. </itemset>
  785. </choices>
  786. </select1>
  787. <caption id="caption12" class="search_name" style="left:930px; top:10px; width:98px; height:17px; ">청구구분 :</caption>
  788. <select1 id="combo3" ref="/root/send/srchclamcretflag" class="combo_search" appearance="minimal" style="left:1021px; top:10px; width:80px; height:19px; ">
  789. <choices>
  790. <item>
  791. <label>전체</label>
  792. <value/>
  793. </item>
  794. <item>
  795. <label>일반건진</label>
  796. <value>1</value>
  797. </item>
  798. <item>
  799. <label>구강건진</label>
  800. <value>2</value>
  801. </item>
  802. <item>
  803. <label>암건진</label>
  804. <value>3</value>
  805. </item>
  806. <item>
  807. <label>영유아검진</label>
  808. <value>4</value>
  809. </item>
  810. </choices>
  811. </select1>
  812. <caption id="caption14" class="search_name" style="left:5px; top:35px; width:98px; height:17px; ">파일명 :</caption>
  813. <input id="input4" ref="/root/send/srchclamsisfilename" class="combo_search" style="left:80px; top:35px; width:275px; height:19px; ">
  814. <script type="javascript" ev:event="onkeyup">
  815. <![CDATA[
  816. if(event.keyCode == 13){
  817. inputEnterKey("btn_srch2", "DOMActivate");
  818. }
  819. ]]>
  820. </script>
  821. </input>
  822. <!-- 청구번호 조회조건 삭제 - 20110920_서원식
  823. <caption id="caption12" class="search_name" style="left:670px; top:10px; width:98px; height:17px; ">청구번호 :</caption>
  824. <input id="input3" ref="/root/send/srchclamseqno" style="left:760px; top:10px; width:150px; height:19px; "/>
  825. -->
  826. <button id="btn_srch2" class="btn1_letter2" style="left:1120px; top:25px; width:56px; height:22px; ">
  827. <caption>조회</caption>
  828. <script type="javascript" ev:event="DOMActivate">
  829. <![CDATA[
  830. fGetClamList(); //청구내역 조회
  831. ]]>
  832. </script>
  833. </button>
  834. <caption id="caption17" class="tit_2" style="left:5px; top:70px; width:111px; height:13px; ">청구내역</caption>
  835. <line id="line3" class="line_4" style="x1:1113px; y1:12px; x2:1113px; y2:55px; "/>
  836. <line id="line4" class="line_1" style="x1:5px; y1:89px; x2:1177px; y2:89px; "/>
  837. <button id="button2" class="btn2_letter4" style="left:1113px; top:69px; width:64px; height:19px; ">
  838. <caption>엑셀저장</caption>
  839. <script type="javascript" ev:event="DOMActivate">
  840. <![CDATA[
  841. var fileName = window.fileDialog("save", ",", false, "excel", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  842. if(fileName != "") grd_reqlst.saveExcel(fileName, "SheetName", false, false, "", "", false);
  843. ]]>
  844. </script>
  845. </button>
  846. <button id="button8" class="btn5_letter2" style="left:996px; top:69px; width:42px; height:19px; ">
  847. <caption>저장</caption>
  848. <script type="javascript" ev:event="DOMActivate">
  849. <![CDATA[
  850. fSetCret();
  851. ]]>
  852. </script>
  853. </button>
  854. <button id="button3" class="btn5_letter4" style="left:1044px; top:69px; width:64px; height:19px; ">
  855. <caption>일괄입력</caption>
  856. <script type="javascript" ev:event="DOMActivate">
  857. <![CDATA[
  858. fSetAmtCopy();
  859. ]]>
  860. </script>
  861. </button>
  862. <datagrid id="grd_reqlst" nodeset="/root/main/reqlst/item" caption="선택^청구일자^청구구분^건진장소^파일명^청구금액^공단금액^공단조정액^공단입금액^공단삭감액^공단절사액^공단추가액^보건소(국고)금액^보건소(국고)조정액^보건소(국고)입금액^보건소(국고)삭감액^보건소(국고)절사액^보건소(국고)추가액^청구상태^청구처코드^반환내역^비고^청구번호^healexamgubun" colsep="^" colwidth="40, 80, 90, 70, 200, 80, 80, 80, 80, 80, 80, 80, 107, 119, 123, 122, 118, 115, 80, 100, 55, 200, 80, 100" explorerbar="sortshow" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:5px; top:94px; width:1172px; height:141px; ">
  863. <col checkvalue="Y,N" ref="sel" type="checkbox"/>
  864. <col ref="clamdd" format="yyyy-mm-dd" style="text-align:center; "/>
  865. <col disabled="true" ref="cretflag" type="combo">
  866. <choices>
  867. <item>
  868. <label>일반건진</label>
  869. <value>1</value>
  870. </item>
  871. <item>
  872. <label>구강건진</label>
  873. <value>2</value>
  874. </item>
  875. <item>
  876. <label>암건진</label>
  877. <value>3</value>
  878. </item>
  879. <item>
  880. <label>영유아검진</label>
  881. <value>4</value>
  882. </item>
  883. </choices>
  884. </col>
  885. <col disabled="true" ref="plceflag" type="combo">
  886. <choices>
  887. <itemset nodeset="/root/init/baseinfo/plceflag/A0110">
  888. <label ref="cdnm"/>
  889. <value ref="cdid"/>
  890. </itemset>
  891. </choices>
  892. </col>
  893. <col ref="sisfilename" type="input" style="text-align:left; "/>
  894. <col ref="clamamt" format="(-,+)#,###" style="text-align:right; "/>
  895. <col ref="payinsubamt" format="(-,+)#,###" style="text-align:right; "/>
  896. <col ref="insuadjustamt" format="(-,+)#,###" style="text-align:right; "/>
  897. <col ref="incminsuamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  898. <col ref="insureduamt" format="(-,+)#,###" style="text-align:right; "/>
  899. <col ref="insurestamt" format="(-,+)#,###" style="text-align:right; "/>
  900. <col ref="insuaddamt" format="(-,+)#,###" style="text-align:right; "/>
  901. <col ref="payhealcntramt" format="(-,+)#,###" style="text-align:right; "/>
  902. <col ref="healcntradjustamt" format="(-,+)#,###" style="text-align:right; "/>
  903. <col ref="incmhealcntramt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  904. <col ref="healcntrreduamt" format="(-,+)#,###" style="text-align:right; "/>
  905. <col ref="healcntrrestamt" format="(-,+)#,###" style="text-align:right; "/>
  906. <col ref="healcntraddamt" format="(-,+)#,###" style="text-align:right; "/>
  907. <col disabled="true" ref="clamstat" type="combo" style="text-align:center; ">
  908. <choices>
  909. <item>
  910. <label>청구</label>
  911. <value>N</value>
  912. </item>
  913. <item>
  914. <label>청구취소</label>
  915. <value>C</value>
  916. </item>
  917. <item>
  918. <label>청구완료</label>
  919. <value>Y</value>
  920. </item>
  921. </choices>
  922. </col>
  923. <col ref="clamtrgtcd" type="input" visibility="hidden"/>
  924. <col checkvalue="Y,N" ref="rtnchkyn" type="checkbox" visibility="hidden"/>
  925. <col ref="remfact" type="input"/>
  926. <col ref="clamseqno" style="text-align:left; "/>
  927. <col ref="healexamgubun" visibility="hidden"/>
  928. <script type="javascript" ev:event="onaftersort">
  929. <![CDATA[
  930. grd_reqlst.gridToInstance();
  931. ]]>
  932. </script>
  933. <script type="javascript" ev:event="xforms-value-changed">
  934. <![CDATA[
  935. if(grd_reqlst.colRef("sel") == grd_reqlst.col){
  936. fGetClamDetlList();
  937. }
  938. ]]>
  939. </script>
  940. <!--
  941. <script type="javascript" ev:event="onbuttonclick">
  942. <![CDATA[
  943. //fGetComnCd("SMAHA01500", "08" , "cd", grd_reqlst.valueMatrix(grd_reqlst.row , grd_reqlst.colRef("clamtrgtcd")) , grd_reqlst.nodeset + "[" + grd_reqlst.row + "]/clamtrgtcd" );
  944. ]]>
  945. </script>
  946. -->
  947. </datagrid>
  948. <button id="btn_incm" class="btn_sw" group="tab2" selected="true" style="left:69px; top:243px; width:64px; height:22px; ">
  949. <caption>입금내역</caption>
  950. <toggle case="case_incm" ev:event="onclick"/>
  951. </button>
  952. <button id="btn_clam" class="btn_sw" group="tab2" selected="true" style="left:5px; top:243px; width:64px; height:22px; ">
  953. <caption>청구내역</caption>
  954. <toggle case="case_clam" ev:event="onclick"/>
  955. </button>
  956. <switch id="switch1" style="left:5px; top:265px; width:1172px; height:441px; ">
  957. <case id="case_clam" selected="true">
  958. <caption id="caption18" class="tit_2" style="left:5px; top:5px; width:111px; height:13px; ">청구상세내역</caption>
  959. <line id="line5" class="line_1" style="x1:5px; y1:24px; x2:1165px; y2:24px; "/>
  960. <button id="btn_rtn2" class="btn5_letter4" style="left:892px; top:4px; width:64px; height:19px; ">
  961. <caption>환자검색</caption>
  962. <script type="javascript" ev:event="DOMActivate">
  963. <![CDATA[
  964. modal("SPAHR00900", "", "", "", "SPAHR00900", "/root/source","/root/target");
  965. ]]>
  966. </script>
  967. </button>
  968. <button id="btn_rtn" class="btn5_letter4" style="left:962px; top:4px; width:64px; height:19px; ">
  969. <caption>선택반환</caption>
  970. <script type="javascript" ev:event="DOMActivate">
  971. <![CDATA[
  972. fSetRtnClam();
  973. ]]>
  974. </script>
  975. </button>
  976. <button id="button4" class="btn5_letter4" style="left:1032px; top:4px; width:64px; height:19px; ">
  977. <caption>일괄입력</caption>
  978. <script type="javascript" ev:event="DOMActivate">
  979. <![CDATA[
  980. fSetDetAmtCopy();
  981. ]]>
  982. </script>
  983. </button>
  984. <button id="btn_detlexcel" class="btn2_letter4" style="left:1101px; top:4px; width:64px; height:19px; ">
  985. <caption>엑셀저장</caption>
  986. <script type="javascript" ev:event="DOMActivate">
  987. <![CDATA[
  988. var fileName = window.fileDialog("save", ",", false, "excel", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  989. if(fileName != "") grd_reqdetllst.saveExcel(fileName, "SheetName", false, false, "", "", false);
  990. ]]>
  991. </script>
  992. </button>
  993. <datagrid id="grd_reqdetllst" nodeset="/root/main/reqdetllst/item" caption="^청구일자^청구번호^성명^주민번호^등록번호^청구금액^공단^조정액^삭감액^절사액^추가액^보건소(국고)^조정액^삭감액^절사액^추가액^청구상태^검사코드^healexamflag^rsrvdd^rsrvno^healexamgubun^plceflag" colsep="^" colwidth="21, 66, 57, 57, 90, 60, 60, 60, 60, 60, 60, 60, 78, 60, 60, 60, 60, 65, 87, 100, 100, 100, 100, 100" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:5px; top:29px; width:1160px; height:405px; color:#ff0000; ">
  994. <col checkvalue="Y,N" ref="sel" type="checkbox"/>
  995. <col ref="clamdd" format="yyyy-mm-dd" style="text-align:center; "/>
  996. <col ref="clamseqno" visibility="hidden" style="text-align:left; "/>
  997. <col ref="hngnm" style="text-align:center; "/>
  998. <col editable="false" ref="rrgstno" type="input" format="999999-9999999" style="text-align:center; "/>
  999. <col ref="pid" style="text-align:center; "/>
  1000. <col ref="clamamt" format="(-,+)#,###" style="text-align:right; "/>
  1001. <col ref="payinsubamt" format="(-,+)#,###" style="text-align:right; "/>
  1002. <col ref="insuadjustamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  1003. <col ref="insureduamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  1004. <col ref="insurestamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  1005. <col ref="insuaddamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  1006. <col ref="payhealcntramt" format="(-,+)#,###" style="text-align:right; "/>
  1007. <col ref="healcntradjustamt" type="input" format="(-,+)#,###" style="left:1070px; top:23px; width:80px; height:23px; text-align:right; "/>
  1008. <col ref="healcntrreduamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  1009. <col ref="healcntrrestamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  1010. <col ref="healcntraddamt" type="input" format="(-,+)#,###" style="text-align:right; "/>
  1011. <col disabled="true" ref="clamstat" type="combo" style="text-align:center; ">
  1012. <choices>
  1013. <item>
  1014. <label>청구</label>
  1015. <value>N</value>
  1016. </item>
  1017. <item>
  1018. <label>청구취소</label>
  1019. <value>C</value>
  1020. </item>
  1021. <item>
  1022. <label>청구반환</label>
  1023. <value>R</value>
  1024. </item>
  1025. <item>
  1026. <label>청구완료</label>
  1027. <value>Y</value>
  1028. </item>
  1029. </choices>
  1030. </col>
  1031. <col ref="testcd"/>
  1032. <col ref="healexamflag" visibility="hidden"/>
  1033. <col ref="rsrvdd" visibility="hidden"/>
  1034. <col ref="rsrvno" visibility="hidden"/>
  1035. <col ref="healexamgubun" visibility="hidden"/>
  1036. <col ref="plceflag" visibility="hidden"/>
  1037. <script type="javascript" ev:event="onaftersort">
  1038. <![CDATA[
  1039. grd_reqdetllst.gridToInstance();
  1040. ]]>
  1041. </script>
  1042. </datagrid>
  1043. </case>
  1044. <case id="case_incm">
  1045. <caption id="caption19" class="tit_2" style="left:5px; top:5px; width:111px; height:14px; ">입금내역</caption>
  1046. <line id="line6" class="line_1" style="x1:5px; y1:24px; x2:1165px; y2:24px; "/>
  1047. <button id="btn_incmexcel" class="btn2_letter4" style="left:1101px; top:4px; width:64px; height:19px; ">
  1048. <caption>엑셀저장</caption>
  1049. <script type="javascript" ev:event="DOMActivate">
  1050. <![CDATA[
  1051. var fileName = window.fileDialog("save", ",", false, "excel", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  1052. if(fileName != "") grd_incmlst.saveExcel(fileName, "SheetName", false, false, "", "", false);
  1053. ]]>
  1054. </script>
  1055. </button>
  1056. <datagrid id="grd_incmlst" nodeset="/root/main/reqdetllst/incm" caption="입금일자^입금구분^심자조정금액^입금액^삭감액^절사액^비고^입력자^청구번호^입금일련번호^카드현금구분^청구처코드^입금상태^healexamgubun" colsep="^" colwidth="100, 80, 100, 100, 100, 100, 200, 100, 100, 100, 100, 100, 100" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" style="left:5px; top:29px; width:1160px; height:405px; ">
  1057. <col ref="incomedd" format="yyyy-mm-dd" style="text-align:center; "/>
  1058. <col ref="incomeflag" type="combo" format="yyyy-mm-dd" style="text-align:left; ">
  1059. <choices>
  1060. <itemset nodeset="/root/init/baseinfo/incomeflaglst/A0458">
  1061. <label ref="cdnm"/>
  1062. <value ref="cdid"/>
  1063. </itemset>
  1064. </choices>
  1065. </col>
  1066. <col ref="chngamt" format="(-,+)#,###" style="text-align:left; "/>
  1067. <col ref="incomeamt" format="(-,+)#,###" style="text-align:left; "/>
  1068. <col ref="discamt" format="(-,+)#,###" style="text-align:left; "/>
  1069. <col ref="restamt" format="(-,+)#,###" style="text-align:left; "/>
  1070. <col ref="remfact" format="(-,+)#,###" style="text-align:left; "/>
  1071. <col ref="userid" style="text-align:left; "/>
  1072. <col ref="clamseqno" style="text-align:left; "/>
  1073. <col ref="incomeseqno" visibility="hidden"/>
  1074. <col ref="cashcardflag" visibility="hidden"/>
  1075. <col ref="clamtrgtcd" visibility="hidden"/>
  1076. <col ref="incomestat" visibility="hidden"/>
  1077. <col ref="healexamgubun" visibility="hidden"/>
  1078. </datagrid>
  1079. </case>
  1080. </switch>
  1081. </case>
  1082. </switch>
  1083. </group>
  1084. <group id="grp_btn" style="left:0px; top:756px; width:1195px; height:27px; ">
  1085. <button id="btn_savecret" class="btn4_letter4" visibility="visible" style="left:946px; top:5px; width:80px; height:22px; ">
  1086. <caption>청구생성</caption>
  1087. <script type="javascript" ev:event="DOMActivate">
  1088. <![CDATA[
  1089. if(isMagmAprv()){
  1090. return false; //마감결제 완료되어있으므로 더이상 진행하지 않음 - PAM.js
  1091. }
  1092. if(case_cret.selected == true){
  1093. if(messageBox("청구생성을","Q004") == 6){
  1094. fSetReqCret(); //청구생성
  1095. fGetReqCretSum();
  1096. }
  1097. }
  1098. ]]>
  1099. </script>
  1100. </button>
  1101. <button id="btn_savaincm" class="btn4_letter4" visibility="visible" style="left:1028px; top:5px; width:80px; height:22px; ">
  1102. <caption>입금저장</caption>
  1103. <script type="javascript" ev:event="DOMActivate">
  1104. <![CDATA[
  1105. if(isMagmAprv()){
  1106. return false; //마감결제 완료되어있으므로 더이상 진행하지 않음 - PAM.js
  1107. }
  1108. if(case_mngt.selected == true) {
  1109. if(messageBox("입금내역을","Q002") == 6){
  1110. fSetClamIncm("I");
  1111. }
  1112. }
  1113. ]]>
  1114. </script>
  1115. </button>
  1116. <button id="btn_clamcncl" class="btn4_letter4" style="left:1110px; top:5px; width:80px; height:22px; ">
  1117. <caption>청구취소</caption>
  1118. <script type="javascript" ev:event="DOMActivate">
  1119. <![CDATA[
  1120. if(isMagmAprv()){
  1121. return false; //마감결제 완료되어있으므로 더이상 진행하지 않음 - PAM.js
  1122. }
  1123. if(case_mngt.selected == true) {
  1124. if(messageBox("청구내역을","Q007") == 6) {
  1125. fExeClamCncl("C");
  1126. }
  1127. }
  1128. ]]>
  1129. </script>
  1130. </button>
  1131. </group>
  1132. </xhtml:body>
  1133. </xhtml:html>